import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

export default new Vuex.Store({
  state: {
    userinfo:{
      avatar:'',
      name:'lisi',
    }
  },
  getters: {
  },
  mutations: {
    // 修改state唯一的途径
    // 提交mutation
    SET_USERINFO(state,data){
      state.userinfo=data
    }
  },
  actions: {
  },
  modules: {
  }
})
